package com.power.sifa.approve.api;

import com.plf.common.domain.ResponseDTO;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;
import com.power.sifa.approve.model.Apl_target;
import com.power.sifa.approve.model.pageInfo.Apl_targetPageInfo;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 *  被申请人 Feign
 */
public interface IApl_targetFeign {

    /**
     * 被申请人分页列表
     */
    @PostMapping("/apl_target/list")
    ResponseDTO list(@RequestBody Apl_targetPageInfo apl_targetPageInfo);

    /**
    * 查看被申请人
    */
    @GetMapping("/apl_target/view")
    ResponseDTO view(@RequestParam("id") String id);

    /**
    * 删除被申请人
    */
    @PostMapping("/apl_target/delete")
    ResponseDTO delete(@RequestParam("id") String id);

    ///**
    // * 查看被申请人 复合主键使用
    // */
    //@PostMapping("/apl_target/viewByPK")
    //ResponseDTO viewByPK(@RequestBody Apl_target.Apl_targetPK pk);

    /**
     * 修改或保存被申请人
     */
    @PostMapping("/apl_target/save")
    ResponseDTO save(@RequestBody Apl_target  apl_target);

    ///**
    // * 删除被申请人 复合主键使用
    // */
    //@PostMapping("/apl_target/deleteByPK")
    //ResponseDTO deleteByPK(@RequestBody Apl_target.Apl_targetPK pk);
    
    /**
     * 批量删除被申请人
     */
    @PostMapping("/apl_target/batchDel")
    ResponseDTO batchDel(@RequestParam("ids") String ids);
    
     /**
     * 导出excel
     */
    @PostMapping("/apl_target/output")
    void output(HttpServletResponse response, @RequestBody Apl_targetPageInfo apl_targetPageInfo);
        
     /**
     * 导出excel模板
     */
    @PostMapping("/apl_target/exportExcelTemplate")
    void exportExcelTemplate(HttpServletResponse response);
    
     /**
     *	导入excel
     */
    @PostMapping("/apl_target/importExcel")
    ResponseDTO importExcel(@RequestBody MultipartFile file) throws IOException ;


    /**
     * 通过applyid查询被申请人信息
     * @param applyid
     * @return
     * @throws IOException
     */
    @PostMapping("/apl_target/getTargetListByApplyid")
    ResponseDTO getTargetListByApplyid(@RequestParam("applyid") String applyid) throws IOException ;
    
}
